package com.itheima.job;

import com.itheima.service.db.AnalysisByDayService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.stereotype.Component;

@Component
public class AnalysisJob {


   @Autowired
    private AnalysisByDayService analysisByDayService;

   @Scheduled(cron = "0/30 * * * * ?")
    public void logToAnalysisBydayJob(){
       System.out.println("日志同步start...");
       analysisByDayService.logToAnalysisByDay();
       System.out.println("日志同步end...");

   }

}
